[LINUX] Various fixes for mmapping I/O and foreign memory pages.
authorkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Mon, 9 Oct 2006 09:56:17 +0000 (10:56 +0100)
committerkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Mon, 9 Oct 2006 09:56:17 +0000 (10:56 +0100)
commit507cd504b6adfc413996aa77bc854dc9879e2b9c
treee55a77d39db31dae23be5d8bd51dbecc65f0312a
parente30cc6aed69eabd142b640c7a15298e1850a655e
[LINUX] Various fixes for mmapping I/O and foreign memory pages.

First, auto-translate guests can use remap_pfn_range() rather than
direct_remap_pfn_range(). This actually works better because
remap_pfn_range() can legitimately assert VM_PFNMAP (this patch
removes this flag for direct_remap_pfn_range().

There are various cleanups and fixes to the privcmd interface:
 1. VMAs should be searched and used under the mmap semaphore
 2. Mapping should be single shot (since cirect_remap_pfn_range()
    expects the PTEs to be empty when it is called).
 3. Demand-fault population of the privcmd vma should be disallowed.
 4. Various others, including a more thorough check of input args.

Signed-off-by: Keir Fraser <keir@xensource.com>
linux-2.6-xen-sparse/arch/i386/mm/ioremap-xen.c
linux-2.6-xen-sparse/drivers/xen/privcmd/privcmd.c
linux-2.6-xen-sparse/mm/memory.c